<template>
  <view :style="themeColor">
    <view class="page">
      <view class="flex benben-position-layout flex flex-wrap align-center haveContacted_flex_0"
        :style="{height:(88+StatusBarRpx)+'rpx',paddingTop:StatusBarRpx+'rpx', }">
        <view class='flex flex-wrap align-center justify-between flex-sub haveContacted_fd0_0'>
          <view class='flex flex-wrap align-center haveContacted_fd0_0_c0' @tap.stop="handleJumpDiy" data-type="back"
            data-url="1">
            <text class='fu-iconfont2  haveContacted_fd0_0_c0_c0'>&#xE794;</text>
          </view>
          <view class='flex flex-wrap align-stretch justify-center'>
            <text class='haveContacted_fd0_0_c1_c0'>我联系过</text>
          </view>
          <view class='flex flex-wrap align-center justify-end haveContacted_fd0_0_c0'>
          </view>
        </view>

      </view>
      <view :style="{height: (88+StatusBarRpx)+'rpx'}"></view>
      <!---flex布局flex布局开始-->
      <view class="flex flex-direction flex-wrap align-stretch benben-flex-layout haveContacted_flex_1">
        <view class='flex flex-direction flex-wrap align-stretch haveContacted_fd1_0' v-for="(item,index) in dataList"
          @tap.stop="handleJumpDiy" data-type="navigateTo"
          :data-url="`/pages/shouye/saleDetails/saleDetails?aid=${item.buy_id}`" :key="index">
          <view class='flex flex-wrap align-center'>
            <text class='haveContacted_fd1_0_c0_c0'>{{item.buy_info.fenlei_name}}</text>
            <image class='haveContacted_fd1_0_c0_c1' mode="aspectFit" :src='STATIC_URL+"2.png"'></image>
            <text class='haveContacted_fd1_0_c0_c0'>{{item.buy_info.shuliang}}吨</text>
            <view class='flex flex-wrap align-center haveContacted_fd1_0_c0_c3'>
              <text
                class='haveContacted_fd1_0_c0_c3_c0'>{{item.buy_info.zhuangchejiage=='-1' ?'电话沟通' : item.buy_info.zhuangchejiage}}</text>
              <text class='haveContacted_fd1_0_c0_c3_c1' v-if="item.buy_info.zhuangchejiage!='-1'">元/斤</text>
            </view>
          </view>
          <view class='flex flex-wrap align-center haveContacted_fd1_0_c1'>
            <image class='haveContacted_fd1_0_c1_c0' v-if="item.buy_info.fenlei==1" mode="aspectFill"
              :src='item.buy_info.tupian[0]'></image>
            <image class='haveContacted_fd1_0_c1_c0' v-if="item.buy_info.fenlei==2" mode="aspectFill"
              src='/static/logo.png'>
            </image>
            <view class='flex flex-direction flex-wrap align-start'>
              <view class='flex flex-wrap align-center'>
                <text class='haveContacted_fd1_0_c1_c1_c0_c0'>地区</text>
                <view class='text-cut haveContacted_fd1_0_c1_c1_c0_c1' style="width: 260rpx;">{{item.buy_info.suozaidi}}
                </view>
              </view>
              <view class='flex flex-wrap align-center haveContacted_fd1_0_c1_c1_c1'>
                <text class='haveContacted_fd1_0_c1_c1_c0_c0'>联系时间</text>
                <text class='haveContacted_fd1_0_c1_c1_c0_c1'>{{item.buy_info.create_time}}</text>
              </view>
              <view class='flex flex-wrap align-center haveContacted_fd1_0_c1_c1_c1'>
                <text class='haveContacted_fd1_0_c1_c1_c0_c0'>联系电话</text>
                <text class='haveContacted_fd1_0_c1_c1_c0_c1'>{{item.buy_info.lianxifangshi}}</text>
                <image class='haveContacted_fd1_0_c1_c1_c2_c2' @click.stop="callMobile(item.buy_info.lianxifangshi)"
                  mode="aspectFit" :src='STATIC_URL+"14.png"'></image>
              </view>
            </view>
          </view>
        </view>
      </view>
      <fu-empty :pagingListLoadedAll="pagingListLoadedAll" :pagingListNoListData="pagingListNoListData"
        :listDataLength="listDataLength" :isLoadInit="isLoadInit"></fu-empty>
      <!---flex布局flex布局结束-->


    </view>
  </view>
</template>
<script>
  import pagingList from '@/common/mixin/paging_list.js';
  export default {
    components: {},
    mixins: [pagingList],

    data() {
      return {
        "minixPagingListsApi": "",
        "pageingListApiMethod": "",
        "allowOnloadGetList": false,
        dataList: [],
      };
    },
    computed: {
      themeColor() {
        return this.$store.getters.themeColor
      },

    },
    watch: {},
    onLoad(options) {
      this.getList()
    },
    onUnload() {

    },
    onReady() {

    },
    onShow() {

    },
    onHide() {

    },
    onResize() {

    },
    onPullDownRefresh() {

    },
    onReachBottom(e) {

    },
    onPageScroll(e) {

    },
    methods: {
      callPhone(item) {
        uni.makePhoneCall({
          phoneNumber: item.lianxifangshi
        })
      },
      getList() {
        this.minixPagingListsApi = global.apiUrls.post65d4517a109b9;
        this.pageingListApiMethod = 'post';
        this.allowOnloadGetList = false;
        this.pagingListPostDataContent = {}
        this.listData = [];
        this.dataList = this.listData;
        this.pagingListToggle();
        console.log(this.dataList)
      },
      pagingListPostData() {
        return this.pagingListPostDataContent
      },
    }
  };
</script>
<style lang="scss" scoped>
  .page {
    width: 100vw;
    overflow-x: hidden;
    min-height: calc(100vh - var(--window-bottom));
    background: rgba(248, 248, 250, 1);
    background-size: 100% auto;
  }

  .haveContacted_flex_0 {
    background: #fff;
    width: 750rpx;
    height: 88rpx;
    overflow: hidden;
    z-index: 10;
    top: 0rpx;
    background-size: 100% auto !important;
  }

  .haveContacted_fd0_0_c1_c0 {
    font-size: 36rpx;
    font-weight: 700;
    color: #333333;
    line-height: 50rpx;
  }

  .haveContacted_fd0_0_c0_c0 {
    font-size: 36rpx;
    color: #333;
  }

  .haveContacted_fd0_0_c0 {
    width: 120rpx;
  }

  .haveContacted_fd0_0 {
    padding: 0rpx 32rpx 0rpx 32rpx;
  }

  .haveContacted_flex_1 {
    padding: 24rpx 30rpx 0rpx 30rpx;
  }

  .haveContacted_fd1_0_c1_c1_c2_c2 {
    width: 40rpx;
    height: 40rpx;
    border-radius: 0rpx 0rpx 0rpx 0rpx;
    margin: 0rpx 0rpx 0rpx 24rpx;
  }

  .haveContacted_fd1_0_c1_c1_c1 {
    margin: 26rpx 0rpx 0rpx 0rpx;
  }

  .haveContacted_fd1_0_c1_c1_c0_c1 {
    color: #101010;
    font-size: 28rpx;
    font-weight: 400;
    line-height: 32rpx;
  }

  .haveContacted_fd1_0_c1_c1_c0_c0 {
    margin: 0rpx 24rpx 0rpx 0rpx;
    width: 128rpx;
    color: #999999;
    font-size: 28rpx;
    font-weight: 400;
    line-height: 32rpx;
  }

  .haveContacted_fd1_0_c1_c0 {
    width: 200rpx;
    height: 200rpx;
    border-radius: 16rpx;
    margin: 0rpx 24rpx 0rpx 0rpx;
  }

  .haveContacted_fd1_0_c1 {
    margin: 24rpx 0rpx 0rpx 0rpx;
  }

  .haveContacted_fd1_0_c0_c3_c1 {
    color: #101010;
    font-size: 30rpx;
    font-weight: 700;
    line-height: 32rpx;
  }

  .haveContacted_fd1_0_c0_c3_c0 {
    color: rgba(236, 22, 26, 1);
    font-size: 30rpx;
    font-weight: 700;
    line-height: 32rpx;
  }

  .haveContacted_fd1_0_c0_c3 {
    margin: 0rpx 0rpx 0rpx auto;
  }

  .haveContacted_fd1_0_c0_c1 {
    width: 100rpx;
    height: 50rpx;
    border-radius: 0rpx 0rpx 0rpx 0rpx;
    margin: 0rpx 20rpx 0rpx 20rpx;
  }

  .haveContacted_fd1_0_c0_c0 {
    color: #101010;
    font-size: 32rpx;
    font-weight: 700;
    line-height: 42rpx;
  }

  .haveContacted_fd1_0 {
    background: rgba(255, 255, 255, 1);
    border-radius: 16rpx;
    background-size: 100% auto;
    margin: 0rpx 0rpx 24rpx 0rpx;
    padding: 32rpx 24rpx 32rpx 24rpx;
  }
</style>
